home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Wonky Flux Batch 2019 02
/
Wonky_Flux_Batch_2019-02.zip
/
Wonky Flux Batch 2019-02
/
075 - Clash of Arms.dsk
/
WAR.MAIL.S
< prev
next >
Wrap
Text File
|
2019-02-17
|
15KB
|
493 lines
;E-Mail Module for GBBS.Pro v1.3
;Original Author Unknown
;Albeit a rip-off of other
;peoples work...
;Modified 10/16/88
;Greg W. Davis
;Sysop WEST WORLD
;415-992-4908
;Modified 5/20/89
;Mach Three
;for Clash of Arms
;Sysop The Sound Barrier
;916-758-9540 9600 Baud
public rd.mail
public sd.mail
on nocar goto link.term
goto email
sd.mail
on nocar goto link.term
gosub wr.ltr
goto link.main
killmail
ready "g:war.mail"
if msg(un) ka=1:else ka=0
if not (ka) goto link.main
print \"Trash your messages? ([Y]/N) ";:input @2 zp$
if zp$="N" goto link.main
ready "g:war.mail":kill #msg(un):update
return
rd.mail
gosub rd.mail0
gosub killmail
link.main
link "a:war.start","maincommand"
email
print\ "Diplomacy (?=Menu): ";:input i$:push email
k$=k$+"/"+i$
if (i$="SNOOP") and (info(5)) then goto snoop.pass
if i$="R" then goto rd.mail0
if i$="S" then s=8:goto snd.mail
if i$="I" then goto ignore
if i$="D" then goto dump
if i$="N" then goto note
if (i$="A") or (i$="Q") then pop:gosub killmail:goto link.main
if i$="?" then print chr$(12):print'
_ _ _ _ _ _ _ _ _ _ _ _ _
(_)(_)(_)(_)(_)(_)(_)(_)(_)(_)(_)(_)(_)
| | | |
| | Diplomacy Menu | |
( )_________________________________( )
| | | |
| | (D) Show Diplomacy Notices | |
| | (N) Change Diplomacy Notices | |
| | (R) Read Messages | |
| | (S) Send Messages | |
| | | |
| | (I) Ignore Messages | |
| | (Q) Quit Back to Main | |
|_| _ _ _ _ _ _ _ _ _ _ _ |_|
(_)(_)(_)(_)(_)(_)(_)(_)(_)(_)(_)(_)(_)':return
print\"'"i$"' is not a Commmand. '?'=Help":return
rd.mail0
on nocar goto link.term
print \" ** Read War Messages **"
ready "g:war.mail"
if not msg(un) print \"No messages for you.":return
rd.2
ready #msg(un)
y1=0:y2=0
print
rd.1
y2=y2+1
input#7,i$,a$,h$,ce$
b$=" "
b2$=""
b2$=str$(y2)
if not instr(b2$,fi$) then b$=" >"
if i$<>"" then print b$"#"y2". "a$" "h$
copy #7,#10:clear#10
if i$<>"" then y1=y1+1: goto rd.1:else y2=y2-1
print\"[C/R=Exit] Select 1-"y2" Messages: ";:input @2 i$
if i$="?" then goto rd.2
if i$="" then ma=1:y=0:return
rd.3
x1=val(i$)
if x1<=0 then goto rd.2
ready #msg(un)
y2=0
rd.mail2
y2=y2+1
x=0:input#7,i$,a$,h$,ce$:d=val(i$):ce=val(ce$)
if i$="" then ma=1: y=0:return
if y2=x1 then goto rd.mail3
copy#7,#10:clear#10
goto rd.mail2
rd.mail3
print #x,\md$
setint (2):copy #7,#x
setint (""):print #x,md$\:print #x,"Letter "y2" of "y1
if key(2) goto wr1.ltr
rd.mail4
input@2\"Enter Option [?=Menu] or [C/R]: "i$
k$=k$+"/"+i$
if i$="?" then print'
_ _ _ _ _ _ _ _ _ _ _ _ _
(_)(_)(_)(_)(_)(_)(_)(_)(_)(_)(_)(_)(_)
| | | |
| | Diplomacy Sub-Menu | |
( )_________________________________( )
| | | |
| | (A) Send Reply | |
| | (F) Forward Message | |
| | (N) Next Message | |
| | (R) Re-read Message | |
| | | |
| | (Q) Quit | |
| | _ _ _ _ _ _ _ _ _ _ _ | |
(_)(_)(_)(_)(_)(_)(_)(_)(_)(_)(_)(_)(_)'
if i$="" then i$=str$(y2+1):goto wr1.ltr
if (left$(i$,1)="C") or (i$="N") goto wr1.ltr
if i$="Q" return
if i$="R" rewind:x=0:goto rd.mail3
if (i$="W") and (info(5)) goto wr.mail
if i$="F" goto forward
if i$<>"A" goto rd.mail4
if d=0 print \"Sorry, anonymous sender":goto rd.mail4
print\"Subject : "h$
input@2"Change Subject? (Y/[N]):"i$
if (i$="N") or (i$="") then h$="Re: "+h$:else input@3\"[C/R=None] Subject:"i$:h$= i$
ce=0
open#1,dr$+"omissions"
position #1,1040,d
input #1,a$,b$
close #1
if b$<>"" then print\"A notice outside the embassy reads:"
print\ b$
gosub editor
if not edit(2) print\"No reply made.":fi$=fi$+" "+str$(x1):goto rd.2
print \" \/ Please Wait..";:s=8: gosub wr.ltr
print ".Reply Sent! \/"
fi$=fi$+" "+str$(x1)
goto rd.2
wr.mail
input @2 \"Filename (to write):" i$:if i$="" goto rd.mail4
create i$:rewind:open #1,i$:input #7,i$
append #1:copy #7,#1:close #1 :goto rd.mail4
forward
print \"Forward Message"
a=d:gosub mail.who
if d=0 then d=a:goto rd.mail4
rewind:s=7
r$=".message forwarded":gosub snd.bulk
d=a: goto rd.2
snd.mail
on nocar goto link.term
print \" ** Send Diplomatic Message **"
gosub mail.who
snd.mai1
print:free
if sk=1:gosub carbon
if d=0 return
input@3\"[C/R=War] Subject: " h$
if h$="" then h$="War"
ce=0
open#1,dr$+"omissions"
position #1,1040,d
input #1,a$,b$
close #1
if sk=1 then b$=""
if b$ <>"" print\"A notice outside the embassy reads:"
print\ b$
gosub editor
if not edit(2) print"No Message Sent!": return
if sk=1 then r$=".Carbons Sent! **":else r$=".Message Sent! **"
s=8:goto snd.bulk
Getplyr
close
open #2,dr$+"WAR.MASTER"
position #2,35,(val(gn$)-1),(ka-1)*5:input #2,d
close
i$=str$(d)
return
mail.who
input @2 \"[L]ist Commanders, Name, Player #, or Player Letter : "i$
clear #10:if i$="" then d=0:return
if i$="L" then gosub userlist:goto mail.who
if instr(i$,"ABCDEF") ka=instr(i$,"ABCDEF"):gosub getplyr
gosub mail.wh2: print #10,d\0:return
carbon
print \"** Bulk Mailing **":x=1
y=5:if flag(1) then y=25
bulk1
input @2 \"[L]ist Commanders, Commander # or Name: "i$
if i$="L" then gosub userlist:goto bulk1
if i$="" then d=0:if x=1 return
if i$<>"" gosub mail.wh2:if d=0 goto bulk1
print #10,d:x=x+1:if d if x<y goto bulk1
d=1:return
mail.wh2
if left$(i$,1)="#" then i$=mid$(i$,2):goto snd.num
if val(left$(i$,1)) goto snd.num
d$=i$:if (d$="SYSOP") or (d$=sys$) then d=1:return
if not instr(" ",i$) d$=". "+d$
open #1,"b:users":d=1
snd.user
position #1,128,d
input #1,a$,b$\c$
if not a$+" "+b$=d$ goto d.1
open #2,dr$+"omissions"
position #2,1040,d
input #2,b1$,bd$:close #2
na$=a3$
if b1$="" goto d.d
if instr(na$,b1$) then print\'Sorry, this commander has expulded your diplomats, and refuses to answer any messages.':d=0: close #1 :return
d.d
na$=a$+" "+b$
if instr(na$,d$) then close: return
d.1
if d<nu then d=d+1:goto snd.user
close #1:d=0
print \d$" is not a Commander.":return
snd.usr2
print \"That person is not a Commander."\
d=0:return
snd.num
d=val(i$)
if (d<1) or (d>nu) goto snd.usr2
move ram,58 to ram2:open #1,"b:users"
position #1,128,d:input #1,a$,b$\c$
position #1,128,d,70:read #1,ram,58
close:if a$="" goto snd.usr2
na$=a3$
open #1,dr$+"omissions"
position #1,1040,d
input #1,b$,i$:close #1
if b$="" then goto snd.num1
if instr(na$,b$) then print\'
Sorry, this commander has expulded your diplomats, and refuses to answer any messages.':d=0:goto snd.num2
snd.num1
print \"Send to Commander "c$\"Last on "when$;
input @2 "? ([Y]/N):" i$
if left$(i$,1)="N" then d=0
snd.num2
move ram2,58 to ram
return
snd.bulk
fo$=""
print \"** Please Wait..";:mark(10)=0
snd.blk2
input #10,d:if d=0 print r$:return
fo$=fo$+"+"+str$(d)
gosub wr.ltr:goto snd.blk2
wr.ltr
on nocar goto link.term
a$=a3$
a$=a$+" (#"+right$("000"+str$(un),3)+")"
y=len(a$)
y=27-y
a$=a$+chr$(32,y)
ready "g:war.mail"
if info(6)<29 print \"Mail bit-map full. Notify Sysop IMMEDIATELY!":return
print #msg(d),un,a$,h$,ce
if t$<>"" then print#6,t$
print #6,"Commander: "a3$" (#"un")"
when$=date$
print #6,"Received : "time$" on "date$
print #6,"Subject : "h$\
copy #s,#6
print #msg(d),chr$(4);chr$(0);
msg(d)=1:update:return
; enter message
editor
free
print\"Enter War Message Now. .S to Send your diplomats, DONE to edit."
cl=clock(2):clock(2)=0:edit(0):edit(1):clock(2)=cl:return
; display file to screen
show.file
setint(1):print \s$\:open #1,f$:if mark(1) close #1:return
showfl2
copy (20) #1
if (eof(1) or key(1)) setint(""):close #1:return
if not flag(35) goto showfl2
print "Press <RETURN> ";:get i$:if i$=chr$(13) print " ";
print chr$(8,16);chr$(32,16);chr$(8,16);
if i$=" " setint(""):close #1:return
setint(1):goto showfl2
wr1.ltr
gosub wr1.lt1
fi$=fi$+" "+str$(x1)
i$=mid$(i$,2):a=val(i$)
if a then goto rd.3
goto rd.2
wr1.lt1
if d=0 then return
if ce=0 then return
edit(0): s=8:gosub wr.ltr.recieved
return
wr.ltr.recieved
if ma=1 then return
b2$=str$(x1)
if instr(b2$,fi$) then return
a$="Post Office "
ready "g:war.mail"
if info(6)<29 print \"Mail bit-map full! Notify Sysop IMMEDIATELY!!":return
print #msg(d),0,a$,h$
print #6,"From : Post Office"
print #6,"Sent to : "a3$" (#"un"):
print #6,"Subject : "h$
when$=date$
print #6,"Received: "time$" on "date$\
print #6," No Reply"
print #6," to your last"
print #6," letter!"
copy #s,#6:print #msg(d),chr$(4);chr$(0);
msg(d)=1:update:return
ignore
print\" <> Ignore Messages From Commanders <>"
print " (These Commanders may not send mail to you)"
print\\"Current Omissions Are:";
create dr$+"omissions":open #1,dr$+"omissions"
position #1,1040,un
input #1,a$,b$
close #1
print a$
ignore1
input\"[?=Menu] Ignore :"i$:push ignore1
if i$="C"then goto clear
if i$="A"then goto add
if i$="V"then goto ignore
if i$="Q"then goto email
if i$="?"then print'
(C) Clear Omissions (A) Add Omissions
(V) View Omissions (Q) Quit':return
print\"( "i$" ) Illegal Command":return
return
clear
create dr$+"omissions"
open #1,dr$+"omissions"
position #1,1040,un
input #1,a$,b$
a$=""
position #1,1040,un
print #1,a$,b$
close #1
print\\"Omissions are now cleared out!"\:return
add
input@3\\"Enter the Commander`s first name :"i$
a$=a$+" "+i$
input@3\\"Enter the Commander`s last name :"i$
a$=a$+" "+i$
create dr$+"omissions"
open #1,dr$+"omissions"
position #1,1040,un
print #1,a$,b$
close #1:return
Note
print\"** Embassy Notice **"
print\"Your notice reads:"\
create dr$+"omissions"
open#1,dr$+"omissions"
position #1,1040,un
input #1,a$,b$
close #1
print b$
input@2\"Change it? (Y/[N]):"i$
if i$<>"Y" then return
print"Enter New notice now :"
input@3\":)"i$
open #1,dr$+"omissions"
position #1,1040,un
print #1,a$,i$
close #1
goto email
dump
print\"Begin at Commander [#1-"nu"] ? ";:input i$
y=val(i$)
if y<1 or y>nu then return
create dr$+"omissions"
open #1,dr$+"omissions"
print\ "User Notices :"\
for x=y to nu
position #1,1040,x
input #1,a$,b$:setint(1)
if b$<>"" then print x":"\b$\
if key(1) setint(""):x=nu
next
close #1:return
userlist
print \" ** List of Commanders **"\
input @2 "Name to Match [Q]uit or [C/R] = All: "i$
if i$="Q" then return
print \s$\
open #1,"b:users":x=1
if left$(i$,1)="#" x=val(mid$(i$,2)):i$=""
if (x=0) or (x>nu) then x=1
print\'
# Name Last on
=========================================='\
usrlst2
position #1,128,x:input #1,a$,b$
setint(1):if a$="" goto usrlst3
a$=a$+" "+b$:if not instr(i$,a$) goto usrlst3
input #1,b$\b$:position #1,128,x,70
move ram,58 to ram2:on nocar goto usrlst4::read #1,ram,58
setint(1)
usrlst2a
p1$=right$(" "+str$(x),4):a$=left$(a$+" ",20)
print p1$" "a$" "when$
usrlst2b
move ram2,58 to ram:on nocar goto link.term
usrlst3
if (not key(1)) and (x<nu) then x=x+1:goto usrlst2
close:return
usrlst4
move ram2,58 to ram
link.term
link "a:main.seg","term1"
snoop.pass
if not info(5) then return
print \"Snooping mail file..."
ready "g:war.mail":open #1,"b:users"
z=2
snoop0
position #1,128,z:input #1,z$,z1$
if (z$="") or (not msg(z)) goto snoop2
print \z$" "z1$" has mail. [R]ead or [Q]uit ? ";
input z$:if z$="Q" then close:return
if z$<>"R" goto snoop2
ready #msg(z)
snoop1
input #7,i$:if i$="" goto snoop2
setint(1)
copy #7:goto snoop1
setint(1)
snoop2
if (not key(1)) and z<nu then z=z+1:goto snoop0
close:return